package com.etonedu.meals.http;

public class HttpUrl {

    // 生产
//    public static String DOMAIN = "http://agw.woniukid.cn/api";
    public static String DOMAIN = "http://123.207.103.39:8080/api";
    public static String FACE = "http://106.52.89.246";
    // 测试
//    public static String DOMAIN = "http://agw.52ess.cn/api";
//    public static String DOMAIN = "http://47.106.165.234:8181/api";
//    public static String FACE = "http://106.52.88.244";

    public static final String MIDDLE = "/nzp-agw-api-server/rest/am/api/url_by_code";

    public static final String FACE_MIDDLE = "/yjy-face/face/v1/multi-identify";

    public static String URL = DOMAIN + MIDDLE;

    public static String FACE_URL = FACE + FACE_MIDDLE;

    public static void setDomain(String url) {
        DOMAIN = url;
        URL = DOMAIN + MIDDLE;
        if ("http://agw.woniukid.cn/api".equals(url)) {
            FACE = "http://106.52.89.246";
            FACE_URL = FACE + FACE_MIDDLE;
        } else if ("http://agw.52ess.cn/api".equals(url)) {
            FACE = "http://106.52.88.244";
            FACE_URL = FACE + FACE_MIDDLE;
        } else if ("http://47.106.165.234:8181/api".equals(url)) {
            FACE = "http://106.52.88.244";
            FACE_URL = FACE + FACE_MIDDLE;
        } else if ("http://123.207.103.39:8080/api".equals(url)) {
            FACE = "http://106.52.89.246";
            FACE_URL = FACE + FACE_MIDDLE;
        }
    }
}
